@extends('admin.main')
@section('body')
    <div class="main-title">
        <h2>编辑购买上下限</h2>
    </div>
    <div class="tab-wrap">
        <div class="tab-content">
            <form action="" method="post" class="form-horizontal">
                <!-- 基础 -->
                <div id="tab1" class="tab-pane in tab1">
                    <div class="form-item">
                        <label class="item-label">
                            用户昵称<span class="check-tips"></span>
                        </label>
                        <div class="controls">
                            <input type="text" name="name" class="text input-large" placeholder=""
                                   value="{{$info ? $info['nickname'] : ''}}">
                        </div>
                    </div>
                    <div class="form-item">
                        <label class="item-label">
                            所属店铺<span class="check-tips"></span>
                        </label>
                        <div class="controls">
                            <input type="text" name="name" class="text input-large" placeholder=""
                                   value="{{$shop ? $shop['shop_name'] : ''}}">
                        </div>
                    </div>
                    <div class="form-item">
                        <label class="item-label">
                            购买下限<span class="check-tips">（必填）</span>
                        </label>
                        <div class="controls">
                            <input type="number" name="buy_min" class="text input-large" min="1" max="100"
                                   value="{{$info ? $info['buy_min'] : ($shop ? $shop['buy_min'] : 1)}}">
                        </div>
                    </div>
                    <div class="form-item">
                        <label class="item-label">
                            购买上限<span class="check-tips">（必填）</span>
                        </label>
                        <div class="controls">
                            <input type="number" name="buy_max" class="text input-large" min="1" max="100"
                                   value="{{$info ? $info['buy_max'] : ($shop ? $shop['buy_max'] : 100)}}">
                        </div>
                    </div>
                    <!-- 高级 -->
                    <div class="form-item">
                        <input type="hidden" name="id" value="{{$info ? $info['id'] : ''}}">
                        <button type="submit" id="submit" class="btn submit-btn ajax-post"
                                target-form="form-horizontal">确 定
                        </button>
                        <button class="btn btn-return" onclick="javascript:history.back(-1);return false;">返 回</button>
                    </div>
                </div>
            </form>
        </div>
    </div>
@endsection
